import request from "@/utils/http";

export const getProvinceDataApi = () => {
    return request.post('/member/areaslist');
}

export const getLocationApi = () => {
    return request.getWithoutBase('https://apis.map.qq.com/ws/location/v1/ip', {
        params: {
            key: 'WQABZ-7OXWJ-42PFE-XPHDG-H5KUV-LJFTK'
        }
    });
};

export const getDistanceApi = (data) => {
    return request.postWithoutBase('https://apis.map.qq.com/ws/distance/v1/matrix?mode=driving', {
        ...data,
        key: 'WQABZ-7OXWJ-42PFE-XPHDG-H5KUV-LJFTK'
    },{header:{"content-type":"application/json"}});
}